<!DOCTYPE html>
<script src="../../resources/js-test.js"></script>
<script>
description('Test for crbug.com/401846 - &lt;iframe&gt; using web font fails to trigger onload() in opener');

window.jsTestIsAsync = true;

window.onload = function() {
  var loaded = 0;
  for (var i = 0; i < 4; ++i) {
    var iframe = document.createElement('iframe');
    iframe.onload = function() {
      loaded++;
      if (loaded == 4)
        finishJSTest();
    };
    iframe.src = 'resources/ahem.html';
    document.body.appendChild(iframe);
  }
};
</script>
